package com.example.factory2;

/**
 * @version 1.0.0
 * @className: TestFactory
 * @description:
 * @author: rosszhang
 * @date: 2022/5/13 11:08
 */
public class TestFactory {
    public static void main(String[] args) {
        Car car=Factory.getCarInstance(3);
        if (car!=null){
            car.run();
            car.stop();
        }else {
            System.out.println("没有此种产品车！！！！");
        }
    }
}
